package com.jlboot.core.base;

import com.jlboot.core.ConfigUtil;
import com.jlboot.core.util.ClientUtil;

import java.io.File;

/**
 * Created by 51594 on 2022/11/10.
 */
public class JfinalCheck {

    /**
     * 检查配置文件
     */
    public static void checkConfig() {
        System.out.println("-----------------------------START---------------------------------------");
        String node = ClientUtil.getWebNode();
        String classpath = ConfigUtil.getWebInfoPath();

        //ehcache的配置文件
        if (!new File(classpath + "/classes/ehcache.xml").exists()) {
            System.out.println("/WEB-INF/classes/ehcache.xml not exit");
        }
        //log4j2.xml
        if (!new File(classpath + "/classes/log4j2.xml").exists()) {
            System.out.println("/WEB-INF/classes/log4j2.xml not exit");
        }

    }
}
